import Vue from 'vue'
import vueRouter  from  'vue-router'
Vue.use(vueRouter)
import example  from '../views/example.vue'//示例

import login from '../views/user/Login.vue'
import regist  from '../views/user/Regist.vue'


const router = [
    {
        path:'/',
        //重定向到home
        redirect: '/login'
    },
    {
        path: '/login',//登录
        component: login
    },
    {
        path: '/regist',//注册
        component: regist
    },
    {
        path: '/example',//示例
        component: example
    },
    
];

export default new vueRouter({
    mode: "hash", 
    routes: router,
    //打包
    base: "dist",
  });